<%@ page language="java" contentType="text/html; charset=UTF-8"
    pageEncoding="UTF-8"%>
     <%@ taglib uri="http://tiles.apache.org/tags-tiles" prefix="tiles" %>
      <%@ taglib uri="http://java.fckeditor.net" prefix="FCK" %>
      <%@taglib prefix="s" uri="/struts-tags"%>
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>Insert title here</title>
</head>
<link href="../sample.css" rel="stylesheet" type="text/css" />
		<link rel="shortcut icon" href="../fckeditor.gif"
				type="image/x-icon" />
<script type="text/javascript" src="js/jquery.js"></script>
		<script type="text/javascript">
			function FCKeditor_OnComplete(editorInstance) {
				var oCombo = document.getElementById('cmbSkins') ;
	
				// Get the active skin.
				var sSkin = editorInstance.Config['SkinPath'] ;
				sSkin = sSkin.match( /[^\/]+(?=\/$)/g ) ;
	
				oCombo.value = sSkin ;
				oCombo.style.visibility = '' ;
			}

			function ChangeSkin(skinName) {
				window.location.href = window.location.pathname + "?skin=" + skinName ;
			}
			$(document).ready(function() {
				   $("#orderedlist").addClass("red");
				   $("#orderedlist > li").addClass("blue");
			});
		</script>
<body>


 <tiles:insertTemplate template="/WEB-INF/layout/layout.jsp" flush="true"> 
	<tiles:putAttribute name="right" >
		<div class="main-content">
			<c:if test="${!empty message}">
				<s:property value="message"/>
				<br />
				<br />
			</c:if>
					<s:iterator value="pagination.results" status="status">
						<br />
						<br />
						<h3><s:property value="sugg_user_name"/> 于<s:property value="sugg_date"/>说：</h3><br />
						${sugg_content}<br />
						<br />
					</s:iterator>
		
			<hr />
			<c:if test="${pagination.no>1}">
			<a href="?pagination.no=1">首页</a>|
			</c:if>
			<c:if test="${pagination.previous}">
			<a href="?pagination.no=${pagination.no-1}&pagination.order=true&pagination.orderFieldName">上页</a>|
			</c:if>
			<c:if test="${pagination.next}">
			<a href="?pagination.no=${pagination.no+1}&pagination.order=true&pagination.orderFieldName">下页</a>|
			</c:if>
			<c:if test="${pagination.no<pagination.pageSum}">
			<a href="?pagination.no=${pagination.pageSum}">末页</a>
			</c:if>
		
			<form action="inputmessage.action" method="post">
				<h5>呢称：</h5><input type="text" name="suggestionBox.sugg_user_name"/><br />
		         <h5>内容：</h5><FCK:editor instanceName="suggestionBox.sugg_content" height="200px" width="400px">
		            <jsp:body>
		               <FCK:config SkinPath="${skin}"/>
		            </jsp:body>
		         </FCK:editor>
		         <hr width="400px"/>
		          <hr width="400px"/>
		         <input type="submit" value="留  言" width="30px" height="40px"/> 
	      </form> 
		</div>
	</tiles:putAttribute>
</tiles:insertTemplate> 
</body>
</html>